package com.wfuhui.modules.order.entity;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

import com.wfuhui.modules.member.entity.MemberEntity;
import com.wfuhui.modules.store.entity.StoreEntity;
import com.wfuhui.modules.store.entity.UserCouponEntity;

import cn.afterturn.easypoi.excel.annotation.Excel;
import cn.afterturn.easypoi.excel.annotation.ExcelCollection;
import cn.afterturn.easypoi.excel.annotation.ExcelEntity;
import cn.afterturn.easypoi.excel.annotation.ExcelTarget;

/**
 * 订单
 * 
 * @author xiaotian
 * @email codemax@qq.com
 * @date 07-14 13:43:12
 */
@ExcelTarget("orderEntity")
public class OrderEntity implements Serializable {
	private static final long serialVersionUID = 1L;

	//
	private Integer id;
	@ExcelEntity(id = "store")
	private StoreEntity store;
	// 订单编号
	@Excel(name = "订单编号", width = 30, isImportField = "order_number")
	private String orderNumber;
	@ExcelEntity(id = "user")
	private MemberEntity user;
	// 订单金额
	@Excel(name = "订单金额", width = 30, isImportField = "total_amount")
	private BigDecimal totalAmount;
	// 订单状态，1：待付款，2：代发货，3：代收货，4：已完成
	private Integer orderStatus;
	// 创建时间
	@Excel(name = "下单时间", width = 30, isImportField = "create_time", exportFormat = "yyyy-MM-dd HH:mm:ss")
	private Date createTime;

	@ExcelCollection(name = "订单商品")
	private List<OrderGoodsEntity> orderGoodsList;

	private Long userId;

	// 备注
	private String remark;

	private String courierNum;
	
	private Integer storeId;
	
	private Integer couponId;
	
	private UserCouponEntity userCoupon;
	
	private String prepayId;
	
	private String formId;

	private Date payTime;


	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	/**
	 * 设置：订单编号
	 */
	public void setOrderNumber(String orderNumber) {
		this.orderNumber = orderNumber;
	}

	/**
	 * 获取：订单编号
	 */
	public String getOrderNumber() {
		return orderNumber;
	}

	public BigDecimal getTotalAmount() {
		return totalAmount;
	}

	public void setTotalAmount(BigDecimal totalAmount) {
		this.totalAmount = totalAmount;
	}

	/**
	 * 设置：订单状态，1：待付款，2：代发货，3：代收货，4：已完成
	 */
	public void setOrderStatus(Integer orderStatus) {
		this.orderStatus = orderStatus;
	}

	/**
	 * 获取：订单状态，1：待付款，2：代发货，3：代收货，4：已完成
	 */
	public Integer getOrderStatus() {
		return orderStatus;
	}

	/**
	 * 设置：创建时间
	 */
	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	/**
	 * 获取：创建时间
	 */
	public Date getCreateTime() {
		return createTime;
	}

	public List<OrderGoodsEntity> getOrderGoodsList() {
		return orderGoodsList;
	}

	public void setOrderGoodsList(List<OrderGoodsEntity> orderGoodsList) {
		this.orderGoodsList = orderGoodsList;
	}

	public Long getUserId() {
		return userId;
	}

	public void setUserId(Long userId) {
		this.userId = userId;
	}
	
	public String getRemark() {
		return remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}

	public String getCourierNum() {
		return courierNum;
	}

	public void setCourierNum(String courierNum) {
		this.courierNum = courierNum;
	}

	public Integer getStoreId() {
		return storeId;
	}

	public void setStoreId(Integer storeId) {
		this.storeId = storeId;
	}

	public StoreEntity getStore() {
		return store;
	}

	public void setStore(StoreEntity store) {
		this.store = store;
	}

	public Integer getCouponId() {
		return couponId;
	}

	public void setCouponId(Integer couponId) {
		this.couponId = couponId;
	}

	public UserCouponEntity getUserCoupon() {
		return userCoupon;
	}

	public void setUserCoupon(UserCouponEntity userCoupon) {
		this.userCoupon = userCoupon;
	}

	public String getPrepayId() {
		return prepayId;
	}

	public void setPrepayId(String prepayId) {
		this.prepayId = prepayId;
	}

	public String getFormId() {
		return formId;
	}

	public void setFormId(String formId) {
		this.formId = formId;
	}

	public Date getPayTime() {
		return payTime;
	}

	public void setPayTime(Date payTime) {
		this.payTime = payTime;
	}

	public MemberEntity getUser() {
		return user;
	}

	public void setUser(MemberEntity user) {
		this.user = user;
	}
	
}
